/*    */ package server.maps;
/*    */ 
/*    */ import client.MapleCharacter;
/*    */ import client.MapleClient;
/*    */ import tools.packet.SummonPacket;
/*    */ 
/*    */ public class MapleDragon
/*    */   extends AnimatedMapleMapObject {
/*    */   private int owner;
/*    */   private int jobid;
/*    */   
/*    */   public MapleDragon(MapleCharacter owner) {
/* 13 */     this.owner = owner.getId();
/* 14 */     this.jobid = owner.getJob();
/* 15 */     if (this.jobid < 2200 || this.jobid > 2218) {
/* 16 */       throw new RuntimeException("试图生成1个龙龙的信息，但角色不是龙神职业.");
/*    */     }
/* 18 */     setPosition(owner.getTruePosition());
/* 19 */     setStance(4);
/*    */   }
/*    */   
/*    */   public void setJobid(int jobid) {
/* 23 */     this.jobid = jobid;
/*    */   }
/*    */ 
/*    */   
/*    */   public void sendSpawnData(MapleClient client) {
/* 28 */     client.announce(SummonPacket.spawnDragon(this));
/*    */   }
/*    */ 
/*    */   
/*    */   public void sendDestroyData(MapleClient client) {
/* 33 */     client.announce(SummonPacket.removeDragon(this.owner));
/*    */   }
/*    */   
/*    */   public int getOwner() {
/* 37 */     return this.owner;
/*    */   }
/*    */   
/*    */   public void setOwner(int owner) {
/* 41 */     this.owner = owner;
/*    */   }
/*    */   
/*    */   public int getJobId() {
/* 45 */     return this.jobid;
/*    */   }
/*    */ 
/*    */   
/*    */   public MapleMapObjectType getType() {
/* 50 */     return MapleMapObjectType.SUMMON;
/*    */   }
/*    */ }


/* Location:              C:\PGX\Server.jar!\server\maps\MapleDragon.class
 * Java compiler version: 8 (52.0)
 * JD-Core Version:       1.1.3
 */